#!/bin/bash

#clear
num=$[RANDOM%10+1]
read -p "请输入一个1~10的整数：" guess

if [ $guess -eq $num ];then
   echo "猜对了，就是$num"
   exit
elif [ $guess -lt $num ];then
   echo "错了，您猜小了"
else 
   echo "错了，您猜大了"
fi
sh guess_num.sh
